<script setup lang="ts">
import { HJNodeType } from '../../types/comTypes';

import { AddRectangleIcon } from 'tdesign-icons-vue-next';

const emits = defineEmits(['addNode']);

const options = [
  { content: '数字输入', value: HJNodeType.numberInput },
  { content: '数字计算', value: HJNodeType.numberFunction },
  { content: '数字输出', value: HJNodeType.numberResult },
];

const clickHandler = (data) => {
  emits('addNode', data.value);
};
</script>

<template>
  <t-dropdown :options="options" trigger="hover" @click="clickHandler">
    <AddRectangleIcon color="#fff" size="30px" />
  </t-dropdown>
</template>

<style scoped lang="less"></style>
